<script setup lang="ts">
import type { ISuperCard,IGoods } from '@/types'
import { useRouter } from 'vue-router'
import { useAsync } from '@/use/useAsync'
import { useAuth } from '@/use/useAuth'
import { fetchOrderData } from '@/api/order'
import OpLoadingView from '@/components/OpLoadingView.vue'

const router = useRouter()
const { user, logout } = useAuth()
const { data, pending } = useAsync(fetchOrderData, {
   goods: {} as IGoods,
})

</script>

<template>

  <div v-for="v in data.data" :key="v" >
    
     <div v-for="i in v.goods" :key="i.id" >
       {{ i }}
          <div  class="box">
            <img :src="i.imgUrl" alt="">
             <h2>{{i.name}}</h2>
            
          </div>
     </div>
  </div>
</template>

<style scoped>
  .box {
    margin: 10px auto;
    border: 2px  solid red;
  }
</style>
